package com.jztd.platfrom.base.exception;

import lombok.Getter;

import java.io.Serializable;

/**
 * 通用服务异常
 */
@Getter
public class ServiceException extends RuntimeException implements Serializable {
    private static final long serialVersionUID = 1L;
    private int code;

    private ServiceException() {
        super("");
    }

    public ServiceException(String message) {
        super(message);
    }

    public ServiceException(String message, int code) {
        super(message);
        this.code = code;
    }

    public ServiceException(String message, int code, Serializable details) {
        super(message);
        this.code = code;
    }
}
